home *** CD-ROM | disk | FTP | other *** search
/ Amiga Tools 5 / Amiga Tools 5.iso / tools / developer-tools / aros / source / exec / internal / m68k / m68k-emul / enable.s < prev    next >
Encoding:
Text File  |  1996-07-16  |  521 b   |  27 lines

  1.     Switch        =    -0x24
  2.     IDNestCnt   =    0x126
  3.     TDNestCnt   =    0x127
  4.     AttnResched =    0x12a
  5.  
  6.     .globl    _Exec_Enable
  7. _Exec_Enable:
  8.     | decrement nesting count and return if there are Disable()s left
  9.     subqb    #1,a6@(IDNestCnt)
  10.     jpl    end
  11.  
  12.     | return if there are no delayed switches pending.
  13.     tstb    a6@(AttnResched+1)
  14.     jpl    end
  15.  
  16.     | if TDNestCnt is not -1 taskswitches are still forbidden
  17.     tstb    a6@(TDNestCnt)
  18.     jpl    end
  19.  
  20.     | Unset delayed switch bit and do the delayed switch
  21.     bclr    #7,a6@(AttnResched+1)
  22.     jsr    a6@(Switch)
  23.  
  24.     | all done.
  25. end:    rts
  26.  
  27.